<div class="content_wrapper">
<div class="content_wrapper_inner"><?php echo validation_errors(); ?> <?php echo form_open('bookflight/payfly'); ?>
<div class="showBox">
<div style="float:left"><h5><?php echo $this->lang->line('profile_information');?></h5></div>
<div id="reqFields"><?php echo $this->lang->line('required_fields');?></div>
<br />
<div class="passengers">
	<table id="itinirary">
		<thead>
			<tr>
				<th align="left" width="70"><?php echo $this->lang->line('title');?></th>
				<th align="left" width="70"><?php echo $this->lang->line('name');?></th>
				<th align="left" width="70"><?php echo $this->lang->line('surname');?></th>
			</tr>
		</thead>
		<tbody>
		<?php
		$passengers=$pnr_xml->xpath('//Passenger');
		foreach($passengers as $passenger) {?>
			<tr>
				<td><?php echo $passenger->title;?></td>
				<td><?php echo $passenger->name ;?></td>
				<td><?php echo $passenger->surname;?></td>
			</tr>
			<?php }?>
		</tbody>
	</table>
</div>
</div>
<br />
<div class="showBox" style="font-size:12px;">
<h5><?php echo $this->lang->line('itinirary');?></h5><br>
		<?php if ($this->session->userdata('search_form_adults') > 0) {
			echo $this->session->userdata('search_form_adults') .' '. $this->lang->line('adult');
		} ?> <?php if ($this->session->userdata('search_form_children') > 0) {
			echo '| ' . $this->session->userdata('search_form_children') .' '. $this->lang->line('child');
		} ?> <?php if ($this->session->userdata('search_form_infants') > 0) {
			echo '| ' . $this->session->userdata('search_form_infants') .' '. $this->lang->line('infant');
		} ?> <?php if ($this->session->userdata('search_form_students') > 0) {
			echo '| ' . $this->session->userdata('search_form_students') .' '. $this->lang->line('student');
		} ?> <?php if ($this->session->userdata('search_form_elders') > 0) {
			echo '| ' . $this->session->userdata('search_form_elders') .' '. $this->lang->line('elder');
		} ?><?php if ($this->session->userdata('search_form_military') > 0) {
			echo '| ' . $this->session->userdata('search_form_military') .' '. $this->lang->line('military');
		} ?>
		<br><br>
	<div style="margin-left: -14px; padding-top:6px;">
	<table class="tb_available" style="width:675px;">
	<thead>
	</thead>
	<tbody>
		<tr>
			<td class="miniTable"><?php echo $this->lang->line('flight');?></td>
			<td class="miniTable"><?php echo $this->lang->line('from');?></td>
			<td class="miniTable"><?php echo $this->lang->line('to');?></td>
			<td class="miniTable"><?php echo $this->lang->line('date');?></td>
			<td class="miniTable"><?php echo $this->lang->line('take_off');?></td>
			<td class="miniTable"><?php echo $this->lang->line('landing');?></td>
			<td class="miniTable"><?php echo $this->lang->line('cabin');?></td>
		</tr>
	<?php
	$segments = $pnr_xml->xpath('//segment');
	foreach($segments as $segment) {?>
		<tr>
			<td class="miniTable2"><?php echo $segment->flightNumber;?></td>
			<td class="miniTable2"><?php echo $segment->from;?></td>
			<td class="miniTable2"><?php echo $segment->to;?></td>
			<td class="miniTable2"><?php echo $segment->date;?></td>
			<td class="miniTable2"><?php echo $segment->departureTime;?></td>
			<td class="miniTable2"><?php echo $segment->arrivalTime;?></td>
			<td class="miniTable2"><?php echo $segment->cabin;?></td>
		</tr>
		<?php }?>
	</tbody>
</table>
</div>
<br>
<br />
<table id="pax_table" border="0" cellpadding="0" cellspacing="0">
	<tr>
		<script>
      		$(function() {
			   $("#phone").mask("0(999) 999-9999");
			});
      	</script>
		<td><?php echo $this->lang->line('phone');?>(*)</td>
		<td width="150"><input maxlength="20" size="18" type="text" name="pax_phone" id="phone"
			value="<?php echo set_value('pax_phone'); ?>"></td>
		<td><?php echo $this->lang->line('e_mail');?></td>
		<td width="150"><input maxlength="20" size="18" type="text" name="pax_email"
			value="<?php echo set_value('pax_email'); ?>"></td>
		<td><?php echo $this->lang->line('corporate_pin');?></td>
		<td><input maxlength="11" size="15" type="text"
			name="pax_corporate_pin"
			value="<?php echo set_value('pax_corporate_pin'); ?>"></td>
	</tr>
</table>
</div>
<br />
<div class="showBox">
<h5><?php echo $this->lang->line('receipt_information');?></h5><br>
<div>
<div style="float: left;">
<table id="receipt_table" border="0" cellpadding="0" cellspacing="0">
	<tr>
		<td><?php echo $this->lang->line('adress');?>(*)</td>
		<td width="150"><input size="17" type="text" name="receipt_address"
			value="<?php echo set_value('receipt_address'); ?>"></td>
	</tr>
	<tr>
		<td><?php echo $this->lang->line('city');?>(*)</td>
		<td><input size="17" type="text" name="receipt_city"
			value="<?php echo set_value('receipt_city'); ?>"></td>
	</tr>
	<tr>
		<td><?php echo $this->lang->line('country');?>(*)</td>
		<td><input size="17" type="text" name="receipt_country"
			value="<?php echo set_value('receipt_country'); ?>"></td>
	</tr>
	<tr>
		<td><?php echo $this->lang->line('zip_code');?>(*)</td>
		<td><input size="17" type="text" name="receipt_zip_code"
			value="<?php echo set_value('receipt_zip_code'); ?>"></td>
	</tr>
	<tr>
		<td><?php echo $this->lang->line('tc_identity');?></td>
		<td><input size="17" type="text" name="receipt_tc_number"
			value="<?php echo set_value('receipt_tc_number'); ?>"></td>
	</tr>
</table>
</div>
<div>
<table id="receipt_table" border="0" cellpadding="0" cellspacing="0">
	<tr>
		<td><?php echo $this->lang->line('is_company');?></td>
		<td><input type="checkbox" name="receipt_is_company" value="1"
		<?php echo set_checkbox('receipt_is_company','1'); ?>></td>
	</tr>
	<tr>
		<td><?php echo $this->lang->line('company_name');?></td>
		<td><input size="17" type="text" name="receipt_company_name"
			value="<?php echo set_value('receipt_company_name'); ?>"></td>
	</tr>
	<tr>
		<td><?php echo $this->lang->line('tax_dapartment');?></td>
		<td><input size="17" type="text" name="receipt_tax_department"
			value="<?php echo set_value('receipt_tax_department'); ?>"></td>
	</tr>
	<tr>
		<td><?php echo $this->lang->line('tax_number');?></td>
		<td><input size="17" type="text" name="receipt_tax_number"
			value="<?php echo set_value('receipt_tax_number'); ?>"></td>
	</tr>
</table>
</div>
</div>
<br><br>
</div>
<br><br><br>
<div style="clear: both; font-family:Verdana; font-size:12px;"><?php echo $this->lang->line('i_red');?> 
	<input type="checkbox" name="read_understood" value="1"	<?php echo set_checkbox('read_understood','1'); ?>> 
	<input type="hidden" name="pnr" value="<?php echo $this->input->get('pnr'); ?>">
	<input type="hidden" name="surname" value="<?php echo $this->input->get('surname'); ?>">
	<button name="submit" value="<?php echo $this->lang->line('buy_now');?>" type="submit"><?php echo $this->lang->line('buy_now');?></button></div>
</div>
</div>
